Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

make MatchPeerCertificatesFromSecret work with certificate chains #664

Conversation

maschmid
Copy link
Contributor

@maschmid maschmid commented Feb 1, 2024

Changes

  • 🧹 make MatchPeerCertificatesFromSecret work with certificate chains

/kind enhancement

When using intermediate CAs, the secret can contain more than one certificate (a certificate chain), so the comparison

for _, cert := range info.Connection.TLS.PemPeerCertificates {
    if cert == string(value) 

cannot work

Instead, we parse all the certificates in the chain from the secret with pem.Decode , and we make sure that each of the certificates is present in the info.Connection.TLS.PemPeerCertificates

@knative-prow knative-prow bot requested review from krsna-m and upodroid February 1, 2024 16:59
@knative-prow knative-prow bot added the size/M Denotes a PR that changes 30-99 lines, ignoring generated files. label Feb 1, 2024
Copy link
Contributor

@matzew matzew left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/lgtm
/approve

@knative-prow knative-prow bot added the lgtm Indicates that a PR is ready to be merged. label Feb 2, 2024
Copy link

knative-prow bot commented Feb 2, 2024

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: maschmid, matzew

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@knative-prow knative-prow bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Feb 2, 2024
@knative-prow knative-prow bot merged commit 3bf004c into knative-extensions:main Feb 2, 2024
24 of 28 checks passed
@maschmid
Copy link
Contributor Author

maschmid commented Feb 2, 2024

/cherry-pick release-1.11

@maschmid
Copy link
Contributor Author

maschmid commented Feb 2, 2024

/cherry-pick release-1.12

@maschmid
Copy link
Contributor Author

maschmid commented Feb 2, 2024

/cherry-pick release-1.13

@knative-prow-robot
Copy link

@maschmid: new pull request created: #665

In response to this:

/cherry-pick release-1.11

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@knative-prow-robot
Copy link

@maschmid: new pull request created: #666

In response to this:

/cherry-pick release-1.12

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@knative-prow-robot
Copy link

@maschmid: new pull request created: #667

In response to this:

/cherry-pick release-1.13

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. kind/enhancement lgtm Indicates that a PR is ready to be merged. size/M Denotes a PR that changes 30-99 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants